package com.sky.dto;

import com.sky.bean.BaseDTO;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.ToString;

import javax.validation.constraints.NotEmpty;

@Data
@ApiModel("新增员工传输对象")
@EqualsAndHashCode(callSuper = true)
@ToString
public class EmployeeDTO extends BaseDTO {
    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "id")
    //TODO 使用参数校验将新增与更新分开
    private Long id;
    @ApiModelProperty(value = "工号/登录账号", position = 1)
    @NotEmpty(message = "工号不可为空")
    private String username;
    @ApiModelProperty(value = "员工姓名",position = 2)
    @NotEmpty(message = "员工姓名不可为空")
    private String name;
    @ApiModelProperty(value = "手机号",position = 3)
    @NotEmpty(message = "手机号不可为空")
    private String phone;
    @ApiModelProperty(value = "性别",position = 4)
    @NotEmpty(message = "性别不可为空")
    private String sex;
    @ApiModelProperty(value = "身份证")
    @NotEmpty(message = "身份证信息不可为空")
    private String idNumber;
}
